
/**
 * @brief    Defines design region for topography (bead or stamp) optimization.
 *
 * @version  0.1
 * @author   wuxingchuang
 * @date     2025.04.11
 *          _
 *      ___| |__   ___ _ __   __ _  ___  _ __   __ _
 *     / __| '_ \ / _ \ '_ \ / _` |/ _ \| '_ \ / _` |
 *     \__ \ | | |  __/ | | | (_| | (_) | | | | (_| |
 *     |___/_| |_|\___|_| |_|\__, |\___/|_| |_|\__, |
 *                           |___/             |___/
 * @copyright (c) 2024 by 神工仿真, All Rights Reserved.
 */
#pragma once
#include "DataStructure/Common/Id.h"
#include "DataStructure/Common/Real.h"
#include "DataStructure/Input/Design/DesignBase.h"

SG_DATASTRUCTURE_FEM_NAMESPACE_OPEN

struct BEADVARData : public DesignBase {
  struct DIRECTIONData {
    SG::DataStructure::Common::I64 m_NORM = 0;      ///<
    SG::DataStructure::Common::Id m_CID1 = 0;       ///<
    SG::DataStructure::Common::Real m_N[3] = {0};   ///<
    SG::DataStructure::Common::Real m_XLB = 0.0;    ///<
    SG::DataStructure::Common::Real m_XUB = 0.0;    ///<
    SG::DataStructure::Common::Real m_DELXV = 0.0;  ///<
  };
  struct GRIDSETData {
    SG::DataStructure::Common::I64 m_NDGSET = 0;  ///<
    SG::DataStructure::Common::I64 m_DGSET = 0;   ///<
  };
  struct PATTERNData {
    SG::DataStructure::Common::Id m_CID3 = 0;     ///<
    SG::DataStructure::Common::I64 m_PATTY = 0;   ///<
    SG::DataStructure::Common::I64 m_PATDIR = 0;  ///<
  };
  struct SYMPLANEData {
    SG::DataStructure::Common::Id m_CID2 = 0;   ///<
    SG::DataStructure::Common::I64 m_MS1 = 0;   ///<
    SG::DataStructure::Common::I64 m_MS2 = 0;   ///<
    SG::DataStructure::Common::I64 m_MS3 = 0;   ///<
    SG::DataStructure::Common::I64 m_CSM = 0;   ///<
    SG::DataStructure::Common::I64 m_NCSM = 0;  ///<
  };

  char m_PTYPE[8] = {0};                         ///<
  SG::DataStructure::Common::Id m_pId = 0;       ///<
  SG::DataStructure::Common::Real m_MW = 0.0;    ///<
  SG::DataStructure::Common::Real m_MH = 0.0;    ///<
  SG::DataStructure::Common::Real m_ANG = 0.0;   ///<
  SG::DataStructure::Common::I64 m_BF = 0;       ///<
  SG::DataStructure::Common::I64 m_SKIP = 0;     ///<
  SG::DataStructure::Common::Id m_domainId = 0;  ///<

  std::vector<DIRECTIONData> m_DIRECTIONList;
  std::vector<GRIDSETData> m_GRIDSETList;
  std::vector<PATTERNData> m_PATTERNList;
  std::vector<SYMPLANEData> m_SYMPLANEList;
};

///@{ @brief operator override
DECLSPEC bool operator==(const BEADVARData::DIRECTIONData& val1,
                         const BEADVARData::DIRECTIONData& val2);
DECLSPEC bool operator==(const BEADVARData::GRIDSETData& val1,
                         const BEADVARData::GRIDSETData& val2);
DECLSPEC bool operator==(const BEADVARData::PATTERNData& val1,
                         const BEADVARData::PATTERNData& val2);
DECLSPEC bool operator==(const BEADVARData::SYMPLANEData& val1,
                         const BEADVARData::SYMPLANEData& val2);

DECLSPEC bool operator==(const BEADVARData& val1, const BEADVARData& val2);
///}@
SG_DATASTRUCTURE_FEM_NAMESPACE_CLOSE
